import { defHttp } from '/@/utils/http/axios';
import { ApiCommon } from '../common';

const { BILLING_ADMIN_API, CUSTOMER_ADMIN_API } = ApiCommon;

enum Api {
  RECORD_BILLS = '/record/business/payments/record/bills', //综合业务办理缴费列表
  LABOR_CHARGE = '/record/business/payments/record/labor/charge', //缴费
  RECORD_BILLS_REFUND = '/record/business/payments/record/bills/refund', // 待退款销账列表
  LABOR_REFUND = '/record/business/payments/record/labor/refund', //退费销账
  WALLET_TRADE_CHARGE= '/wallet-trade-detail/charge', // 预存款充值
  RECORD_BILLS_RELEASE = '/record/business/payments/record/bills/release', // 综合业务办理缴费列表 新版
  LABOR_CHARGE_RELEASE = '/record/business/payments/record/labor/charge/release', // 缴费 新版
}

// 获得缴费列表 
export const getRecordbills = (data: any) =>
  defHttp.post({ url: BILLING_ADMIN_API + Api.RECORD_BILLS, data });

// 缴费
export const getLaborchaarge = (data: any) =>
  defHttp.post({ url: BILLING_ADMIN_API + Api.LABOR_CHARGE, data });

// 待退款销账列表 
export const getRecordbillsRefund = (data: any) =>
defHttp.post({ url: BILLING_ADMIN_API + Api.RECORD_BILLS_REFUND, data });

// 退费销账
export const getLaborTefund = (data: any) =>
  defHttp.post({ url: BILLING_ADMIN_API + Api.LABOR_REFUND, data });
// 预存款充值
export const postWalletTradeCharge = (data: any) =>
defHttp.post({ url: CUSTOMER_ADMIN_API + Api.WALLET_TRADE_CHARGE, data });

// 获得缴费列表-新版
export const getRecordbillsNew = (data: any) =>
  defHttp.post({ url: BILLING_ADMIN_API + Api.RECORD_BILLS_RELEASE, data });

// 缴费
export const getLaborchaargeRelease = (data: any) =>
defHttp.post({ url: BILLING_ADMIN_API + Api.LABOR_CHARGE_RELEASE, data }); 
